home *** CD-ROM | disk | FTP | other *** search
/ CD Actual 2 / CD ACTUAL VOL 2.iso / docs / kernel.13 / readme < prev    next >
Encoding:
Text File  |  1995-09-10  |  10.6 KB  |  242 lines

  1.  
  2.     Linux kernel release 1.3.xx
  3.  
  4. These are the release notes for linux version 1.3.  Read them carefully,
  5. as they tell you what this is all about, explain how to install the
  6. kernel, and what to do if something goes wrong. 
  7.  
  8. Linux version 1.3 is a DEVELOPMENT kernel, and not intended for general 
  9. public use.  Different releases may have various and sometimes severe 
  10. bugs.  It is *strongly* recommended that you back up the previous kernel 
  11. before installing any new 1.3.xx release.
  12.  
  13. If you need to use a proven and stable Linux kernel, please use either 
  14. 1.0.9 or 1.2.xx.  All features which will be in the 1.3.xx releases will 
  15. be contained in 1.4.xx when the code base has stabilized again.
  16.  
  17. If you decide to use 1.3, it is recommended that you join the kernel mailing 
  18. list.  To do this, e-mail majordomo@vger.rutgers.edu, and put in the body 
  19. of the message "subscribe linux-kernel" or "subscribe linux-kernel-digest" 
  20. for a daily digest of the mailing list (it is a high-traffic list.)
  21.  
  22. WHAT IS LINUX?
  23.  
  24.   Linux is a Unix clone for 386/486-based PCs written from scratch by
  25.   Linus Torvalds with assistance from a loosely-knit team of hackers
  26.   across the Net.  It aims towards POSIX compliance. 
  27.  
  28.   It has all the features you would expect in a modern fully-fledged
  29.   Unix, including true multitasking, virtual memory, shared libraries,
  30.   demand loading, shared copy-on-write executables, proper memory
  31.   management and TCP/IP networking. 
  32.  
  33.   It is distributed under the GNU General Public License - see the
  34.   accompanying COPYING file for more details. 
  35.  
  36. DOCUMENTATION:
  37.  
  38.  - there is a lot of documentation available both in electronic form on
  39.    the internet and in books, both Linux-specific and pertaining to
  40.    general UNIX questions.  I'd recommend looking into the documentation
  41.    subdirectories on any Linux ftp site for the LDP (Linux Documentation
  42.    Project) books.  This README is not meant to be documentation on the
  43.    system: there are much better sources available.
  44.  
  45. INSTALLING the kernel:
  46.  
  47.  - If you install the full sources, do a
  48.  
  49.         cd /usr/src
  50.         gzip -cd linux-1.3.XX.tar.gz | tar xfv -
  51.  
  52.    to get it all put in place. Replace "XX" with the version number of the
  53.    latest kernel.
  54.  
  55.  - You can also upgrade between 1.3.xx releases by patching.  For a large
  56.    set of revisions, it is not worth the effort since the full set of 
  57.    patches is bigger than a new kernel distribution. Instead, get the
  58.    latest full source archive and install as above. Then, get all newer
  59.    patch files, and do
  60.  
  61.         cd /usr/src
  62.         gzip -cd patchXX.gz | patch -p0
  63.  
  64.    (repeat xx for all versions bigger than the version of your current
  65.    source tree, _in_order_) and you should be ok.  You may want to remove
  66.    the backup files (xxx~ or xxx.orig), and make sure that there are no
  67.    failed patches (xxx# or xxx.rej). If there are, either you or me has
  68.    made a mistake.
  69.  
  70.  - make sure your /usr/include/linux and /usr/include/asm directories
  71.    are just symlinks to the kernel sources:
  72.  
  73.         cd /usr/include
  74.         rm -rf linux
  75.         rm -rf asm
  76.         ln -s /usr/src/linux/include/linux linux
  77.         ln -s /usr/src/linux/include/asm-i386 asm
  78.  
  79.  - make sure you have no stale .o files and dependencies lying around:
  80.  
  81.         cd /usr/src/linux
  82.         make mrproper
  83.  
  84.    You should now have the sources correctly installed.
  85.  
  86. CONFIGURING the kernel:
  87.  
  88.  - do a "make config" to configure the basic kernel.  "make config"
  89.    needs bash to work: it will search for bash in $BASH, /bin/bash and
  90.    /bin/sh (in that order), so hopefully one of those is correct. 
  91.  
  92.     NOTES on "make config":
  93.     - having unnecessary drivers will make the kernel bigger, and can
  94.       under some circumstances lead to problems: probing for a
  95.       nonexistent controller card may confuse your other controllers
  96.     - compiling the kernel with "-m486" for a number of 486-specific
  97.       will result in a kernel that still works on a 386: it may be
  98.       slightly larger and possibly slower by an insignificant amount,
  99.       but it should not hurt performance. 
  100.     - A kernel with math-emulation compiled in will still use the
  101.       coprocessor if one is present: the math emulation will just
  102.       never get used in that case.  The kernel will be slightly larger,
  103.       but will work on different machines regardless of whether they
  104.       have a math coprocessor or not. 
  105.     - the "kernel hacking" configuration details usually result in a
  106.       bigger or slower kernel (or both), and can even make the kernel
  107.       less stable by configuring some routines to actively try to
  108.       break bad code to find kernel problems (kmalloc()).  Thus you
  109.       should probably answer 'n' to the questions for a "production"
  110.       kernel. 
  111.  
  112.  - Check the top Makefile for further site-dependent configuration
  113.    (default SVGA mode etc). 
  114.  
  115.  - Finally, do a "make dep" to set up all the dependencies correctly. 
  116.  
  117. COMPILING the kernel:
  118.  
  119.  - make sure you have gcc-2.5.8 or newer available.  It seems older gcc
  120.    versions can have problems compiling newer versions of linux.  If you
  121.    upgrade your compiler, remember to get the new binutils package too
  122.    (for as/ld/nm and company). Do not use gcc-2.6.0; it has a few serious
  123.    bugs.  Some problems have been reported occasionally with 2.6.3 as well,
  124.    so use that version at your own risk.
  125.  
  126.  - do a "make zImage" to create a compressed kernel image.  If you want
  127.    to make a bootdisk (without root filesystem or lilo), insert a floppy
  128.    in your A: drive, and do a "make zdisk".  It is also possible to do
  129.    "make zlilo" if you have lilo installed to suit the kernel makefiles,
  130.    but you may want to check your particular lilo setup first. 
  131.  
  132.  - keep a backup kernel handy in case something goes wrong.  This is 
  133.    especially true for the development releases, since each new release
  134.    contains new code which has not been debugged. 
  135.  
  136.  - In order to boot your new kernel, you'll need to copy the kernel
  137.    image (found in /usr/src/linux/arch/i386/boot/zImage after compilation)
  138.    to the place where your regular bootable kernel is found. 
  139.  
  140.    For some, this is on a floppy disk, in which case you can "cp
  141.    /usr/src/linux/arch/i386/boot/zImage /dev/fd0" to make a bootable
  142.    floppy. 
  143.  
  144.    If you boot Linux from the hard drive, chances are you use LILO which
  145.    uses the kernel image as specified in the file /etc/lilo.conf.  The
  146.    kernel image file is usually /vmlinuz, or /zImage, or /etc/zImage. 
  147.    To use the new kernel, copy the new image over the old one (save a
  148.    backup of the original!).  Then, you MUST RERUN LILO to update the
  149.    loading map!! If you don't, you won't be able to boot the new kernel
  150.    image. 
  151.  
  152.    Reinstalling LILO is usually a matter of running /sbin/lilo. 
  153.    You may wish to edit /etc/lilo.conf to specify an entry for your
  154.    old kernel image (say, /vmlinux.old) in case the new one does not
  155.    work.  See the LILO docs for more information. 
  156.  
  157.    After reinstalling LILO, you should be all set.  Shutdown the system,
  158.    reboot, and enjoy!
  159.  
  160.    If you ever need to change the default root device, video mode,
  161.    ramdisk size, etc.  in the kernel image, use the 'rdev' program (or
  162.    alternatively the LILO boot options when appropriate).  No need to
  163.    recompile the kernel to change these parameters. 
  164.  
  165.  - reboot with the new kernel and enjoy. 
  166.  
  167. IF SOMETHING GOES WRONG:
  168.  
  169.  - if you have problems that seem to be due to kernel bugs, please mail
  170.    them to me (Linus.Torvalds@Helsinki.FI), and possibly to any other
  171.    relevant mailing-list or to the newsgroup.  The mailing-lists are
  172.    useful especially for SCSI and NETworking problems, as I can't test
  173.    either of those personally anyway. 
  174.  
  175.  - In all bug-reports, *please* tell what kernel you are talking about,
  176.    how to duplicate the problem, and what your setup is (use your common
  177.    sense).  If the problem is new, tell me so, and if the problem is
  178.    old, please try to tell me when you first noticed it.
  179.  
  180.  - if the bug results in a message like
  181.  
  182.     unable to handle kernel paging request at address C0000010
  183.     Oops: 0002
  184.     EIP:   0010:XXXXXXXX
  185.     eax: xxxxxxxx   ebx: xxxxxxxx   ecx: xxxxxxxx   edx: xxxxxxxx
  186.     esi: xxxxxxxx   edi: xxxxxxxx   ebp: xxxxxxxx
  187.     ds: xxxx  es: xxxx  fs: xxxx  gs: xxxx
  188.     Pid: xx, process nr: xx
  189.     xx xx xx xx xx xx xx xx xx xx
  190.  
  191.    or similar kernel debugging information on your screen or in your
  192.    system log, please duplicate it *exactly*.  The dump may look
  193.    incomprehensible to you, but it does contain information that may
  194.    help debugging the problem.  The text above the dump is also
  195.    important: it tells something about why the kernel dumped code (in
  196.    the above example it's due to a bad kernel pointer)
  197.  
  198.  - in debugging dumps like the above, it helps enormously if you can
  199.    look up what the EIP value means.  The hex value as such doesn't help
  200.    me or anybody else very much: it will depend on your particular
  201.    kernel setup.  What you should do is take the hex value from the EIP
  202.    line (ignore the "0010:"), and look it up in the kernel namelist to
  203.    see which kernel function contains the offending address.
  204.  
  205.    To find out the kernel function name, you'll need to find the system
  206.    binary associated with the kernel that exhibited the symptom.  This is
  207.    the file 'linux/vmlinux'.  To extract the namelist and match it against
  208.    the EIP from the kernel crash, do:
  209.  
  210.         nm vmlinux | sort | less
  211.  
  212.    This will give you a list of kernel addresses sorted in ascending
  213.    order, from which it is simple to find the function that contains the
  214.    offending address.  Note that the address given by the kernel
  215.    debugging messages will not necessarily match exactly with the
  216.    function addresses (in fact, that is very unlikely), so you can't
  217.    just 'grep' the list: the list will, however, give you the starting
  218.    point of each kernel function, so by looking for the function that
  219.    has a starting address lower than the one you are searching for but
  220.    is followed by a function with a higher address you will find the one
  221.    you want.  In fact, it may be a good idea to include a bit of
  222.    "context" in your problem report, giving a few lines around the
  223.    interesting one. 
  224.  
  225.    If you for some reason cannot do the above (you have a pre-compiled
  226.    kernel image or similar), telling me as much about your setup as
  227.    possible will help. 
  228.  
  229.  - alternately, you can use gdb on a running kernel. (read-only; i.e. you
  230.    cannot change values or set break points.) To do this, first compile the
  231.    kernel with -g; edit arch/i386/Makefile appropriately, then do a "make
  232.    clean". You'll also need to enable CONFIG_PROC_FS (via "make config").
  233.  
  234.    After you've rebooted with the new kernel, do "gdb vmlinux /proc/kcore".
  235.    You can now use all the usual gdb commands. The command to look up the
  236.    point where your system crashed is "l *0xXXXXXXXX". (Replace the XXXes
  237.    with the EIP value.)
  238.  
  239.    gdb'ing a non-running kernel currently fails because gdb (wrongly)
  240.    disregards the starting offset for which the kernel is compiled.
  241.  
  242.